/*=====================================================================================================================
 * 
 * Repository path:     $HeadURL: http://pfsmps.googlecode.com/svn/trunk/src/vpwm.h $
 * Last committed:      $Revision: 2 $
 * Last changed by:     $Author: vladislav.gyurov@gmail.com $
 * Last changed date:   $Date: 2013-09-16 20:26:36 +0000 (Mon, 16 Sep 2013) $
 * ID:                  $Id: vpwm.h 2 2013-09-16 20:26:36Z vladislav.gyurov@gmail.com $
 *
 *===================================================================================================================*/
#ifndef __VPWM_H
#define __VPWM_H

/*=====================================================================================================================
 * Included files to resolve specific definitions in this file                
 *===================================================================================================================*/
#include "basedef.h"

/*=====================================================================================================================
 * Constant data                                                              
 *===================================================================================================================*/
/*
** PWM primary time base prescaler
*/
#define cPwmPrimaryTimeBasePrescaler        1

/*
** PWM secondary time base prescaler
*/
#define cPwmSecondaryTimeBasePrescaler      1



/*=====================================================================================================================
 * Exported type                                                             
 *===================================================================================================================*/

/*=====================================================================================================================
 * Exported data                                                              
 *===================================================================================================================*/

/*=====================================================================================================================
 * Constant exported data                                                     
 *===================================================================================================================*/

/*=====================================================================================================================
 * Exported Macros                                                            
 *===================================================================================================================*/
#define _PFC_MASTER_WriteDuty(Duty)         (PDC4 = (Duty))
#define _PFC_SLAVE_WriteDuty(Duty)          (SDC4 = (Duty))
#define _SMPS_WritePhase(Phase)             (PHASE2 = (Phase))

#define _PWMInit()                          PWMInit()
/*=====================================================================================================================
 * Exported functions                     				                        
 *===================================================================================================================*/
extern void PWMInit(void);

#endif /* __VPWM_H */
